package tk.mybatis.springboot.conf;

import org.springframework.boot.web.servlet.ServletRegistrationBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import tk.mybatis.springboot.servlet.MyServlet1;

/**
 * servlet 配置.
 * @author Administrator
 *
 */
@Configuration
public class ServletConfiguration {

	/**
	 * 注册servlet
	 * http://127.0.0.1:9090/myServlet
	 * @return
	 */
	
	@Bean
	public ServletRegistrationBean MyServlet1() {
		ServletRegistrationBean servletRegistrationBean = new ServletRegistrationBean(new MyServlet1(), "/myServlet/*");
		return servletRegistrationBean;
	}



}